import userEvent from '@testing-library/user-event'
import React,{useEffect,useState} from 'react'
import { Button, Space, Swiper, Toast } from 'antd-mobile'
import styles from './index.mobules.css'
export default function Index() {
  const [colors, setColor] = useState([])
  useEffect(()=>{
    setColor(
      ['#ace0ff', '#bcffbd', '#e4fabd', '#ffcfac']
    )
  },[])
  return (
    <div>
      {
        colors.map((color, index) => (
          <Swiper.Item key={index}>
            <div className={styles.content} style={{ background: color }}>
              {index + 1}
            </div>
          </Swiper.Item>
        ))
      }
    </div>
  )
}
